<include file="../Public/header" />
<link rel="stylesheet" href="__PUBLIC__/admin/css/weibo-pic.css?v=20140828" />
<script data-main="__PUBLIC__/admin/js/page/admin/content/weibo" src="__PUBLIC__/admin/js/lib/requirejs/require.js"></script>
</head>

<body>

  <div class="page">
    <div class="page-hd">
      <h1>{$Think.lang.manageweibo}</h1>
    </div>
    <div class="navbar">
      <ul class="nav">
        <li <eq name="other_tab" value="cur"> class="active"</eq>><a href="{:URL('admin/Circle/circlemessagelist')}">播报管理</a>
        </li> 
        <li <eq name="weibo_tab" value="cur">class="active"</eq>><a href="{:URL('admin/Content/weibo')}">{$Think.lang.weibo}</a>
        </li>
        <li <eq name="recycle_tab" value="cur">class="active"</eq>><a href="{:URL('admin/Content/weibo','recycle=1')}">{$Think.lang.recycle}</a>
        </li>
      </ul>
    </div>
    <div class="filterbar">
      <form id="search" method="post">
        <input id="recycle" class="input-text" name="recycle" type="hidden" value="{$recycle}">
        <label for="is_active">微博{$Think.lang.type}</label>
        <select name="type" id="type">
          <option value="" <eq name="type" value="">selected</eq>>{$Think.lang.all}</option>
          <option value="1" <eq name="type" value="1">selected</eq>>图片</option>
          <option value="0" <eq name="type" value="0">selected</eq>>文本</option>
        </select>            
        <label for="is_active">{$Think.lang.status}</label>
        <select name="is_recommend" id="is_recommend">
          <option value="" <eq name="is_recommend" value="">selected</eq>>{$Think.lang.all}</option>
          <option value="1" <eq name="is_recommend" value="1">selected</eq>>{$Think.lang.recommend}</option>
          <option value="0" <eq name="is_recommend" value="0">selected</eq>>{$Think.lang.notrecommend}</option>
        </select>
        <label for="">{$Think.lang.weibo}ID</label>
        <input type="number" name="title" id="weibo_id" value="{$weibo_id}" class="input-text">
        <label for="">{$Think.lang.user}ID</label>
        <input type="number" name="title" id="uid" value="{$uid}" class="input-text">
        <label for="">{$Think.lang.weibocontent}</label>
        <input type="text" name="title" id="content" value="{$content}" class="input-text">
        <button type="submit" class="btn-search" id="J_search" title="{$Think.lang.search}">
          <i class="icon-search"></i>
        </button>
      </form>
    </div>
    <div class="datas">
      <div class="datas-bd">
        <table class="table">
          <thead>
            <tr>
              <th style="width: 10px">
                <input type="checkbox" class="toggle-all" />
              </th>
              <th style='width:45px'>{$Think.lang.weibo}ID</th>
              <th style='width:45px'>{$Think.lang.user}ID</th>
              <th style="width:80px">{$Think.lang.username}</th>
              <th style="">{$Think.lang.data}</th>
              <th style="width:120px">{$Think.lang.publishtime}</th>
              <th style="width:70px">{$Think.lang.weibotype}</th>
              <th style="width:80px">{$Think.lang.fromUser}</th>
              <th style="width:100px">{$Think.lang.operating}</th>
            </tr>
          </thead>
          <tbody>
            <volist id="vo" name="data">
              <tr data-id="{$vo.weibo_id}">
                <td>
                  <input type="checkbox" class="toggle" />
                </td>
                <td>{$vo.weibo_id}</td>
                <td>{$vo.uid}</td>
                <td><a href="{:URL('home/Space/index',array('uid'=>$vo['uid']))}" target="_blank">{$vo.uname}</a>
                </td>
                <td>
                    <a href="{:URL('home/Space/detail',array('id'=>$vo['weibo_id']))}" target="_blank">{$vo.content}</a>
                    <div style="width:500px;" class="thumb">
                        <switch name='vo["type"]'>
                            <case value="3">
                                <img src="{$vo.type_data.img}"  height='90'>
                            </case>
                            <case value='1'>
                                <volist name="vo['type_data']" id="img_data">
                                    <if condition="($key+1)%5 eq 0">
                                        <if condition='$img_data.thumbmiddleurl eq null'>
                                            <a href='{$img_data["picurl"]}' target="_blank" title="点击查看大图">
                                                <img src='{$img_data["picurl"]}' width='90' height='90' />
                                            </a>
                                        <else />
                                            <a href='./data/uploads/{$img_data["thumbmiddleurl"]}' target='_blank' title="点击查看大图">
                                                <img src="./data/uploads/{$img_data['thumburl']}" width="90" height="90"/>
                                            </a>
                                        </if>
                                        <br />
                                    <else />
                                        <if condition='$img_data.thumbmiddleurl eq null'>
                                            <a href='{$img_data["picurl"]}' target="_blank" title="点击查看大图">
                                                <img src='{$img_data["picurl"]}' width='90' height='90' />
                                            </a>
                                        <else />
                                            <a href='./data/uploads/{$img_data["thumbmiddleurl"]}' target='_blank' title="点击查看大图">
                                                <img src="./data/uploads/{$img_data['thumburl']}" width="90" height="90"/>
                                            </a>
                                        </if>
                                    </if>
                                </volist>
                            </case>
                        </switch>
                    </div>
                </td>
                <td>{$vo.ctime|date="Y-m-d H:i",###}</td>
                <td>
                    <switch name='vo.type'>
                        <case value='1'>图片</case>
                        <case value='3'>视频</case>
                        <case value='2'>音乐</case>
                        <default />文本
                    </switch>
                </td>
                <td>{$vo.from}</td>
                <td>
                  <eq name="weibo_tab" value="cur">
	                  <switch name='vo.is_recommend'>
	                        <case value='0'><a href="javascript:;" class="A_recommend">{$Think.lang.recommend}</a>&nbsp;|&nbsp;</case>
	                        <case value='1'><a href="javascript:;" class="A_cancelrecommend" style="color:red">{$Think.lang.cancelrecommend}</a>&nbsp;|&nbsp;</case>
                      </switch>
                    
                    <a href="javascript:;" class="A_screen">{$Think.lang.shield}</a>
                  </eq>
                  <eq name="recycle_tab" value="cur">
                        <a href="javascript:;" class="recover">{$Think.lang.recover}</a>&nbsp;|&nbsp;<a href="javascript:;" class="A_del">{$Think.lang.completelyremove}</a>
                  </eq>
                </td>
              </tr>
            </volist>
          </tbody>
        </table>
      </div>

      <div class="datas-ft">
        <div class="actions">
          <!-- <a href="javascript:;" class="btn" id="J_show">{$Think.lang.search}{$Think.lang.微博}</a> -->
          <eq name="weibo_tab" value="cur">
            <a href="javascript:;" class="btn" id="J_screen">{$Think.lang.shieldweibo}</a>
          </eq>
          <eq name="recycle_tab" value="cur">
            <a href="javascript:;" class="btn" id="J_restore">{$Think.lang.recover}</a>
            <a href="javascript:;" class="btn" id="J_del">{$Think.lang.completelyremove}</a>
          </eq>
        </div>

        <div class="pager">{$page}</div>
      </div>

    </div>

  </div>
  </div>
</body>

</html>
